package mylab.starters.eventbus.support.disruptor;


import com.lmax.disruptor.EventFactory;
import mylab.starters.eventbus.api.EventModel;

/**
 * 事件工厂
 * Disruptor 通过EventFactory在RingBuffer中预创建Event的实例
 *
 * @param <T>
 */
public class EventModelFactory<T> implements EventFactory<EventModel<T>> {
    @Override
    public EventModel<T> newInstance() {
        return new EventModel<>();
    }
}
